<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.6"/>
<title>Paho C++: mqtt::client Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="pahologo.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">Paho C++
   &#160;<span id="projectnumber">1.0</span>
   </div>
   <div id="projectbrief">The Paho MQTT C++ Client Library</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.6 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('classmqtt_1_1client.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Friends</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="classmqtt_1_1client-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">mqtt::client Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>Lightweight client for talking to an MQTT server using methods that block until an operation completes.  
 <a href="classmqtt_1_1client.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="client_8h_source.html">client.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for mqtt::client:</div>
<div class="dyncontent">
 <div class="center">
  <img src="classmqtt_1_1client.png" usemap="#mqtt::client_map" alt=""/>
  <map id="mqtt::client_map" name="mqtt::client_map">
<area href="classmqtt_1_1callback.html" title="Provides a mechanism for tracking the completion of an asynchronous action. " alt="mqtt::callback" shape="rect" coords="0,0,86,24"/>
</map>
 </div></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-types"></a>
Public Types</h2></td></tr>
<tr class="memitem:a0b763b9915200415709ef87e66405d3b"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a0b763b9915200415709ef87e66405d3b"></a>
using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a0b763b9915200415709ef87e66405d3b">ptr_t</a> = std::shared_ptr&lt; <a class="el" href="classmqtt_1_1client.html">client</a> &gt;</td></tr>
<tr class="memdesc:a0b763b9915200415709ef87e66405d3b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Smart pointer type for this object. <br/></td></tr>
<tr class="separator:a0b763b9915200415709ef87e66405d3b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aab7f6333d1b4c20671a879c30139bfbd"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aab7f6333d1b4c20671a879c30139bfbd"></a>
using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#aab7f6333d1b4c20671a879c30139bfbd">qos_collection</a> = <a class="el" href="classmqtt_1_1iasync__client.html#aee95659bed2446d0409ce33479f9cdad">async_client::qos_collection</a></td></tr>
<tr class="memdesc:aab7f6333d1b4c20671a879c30139bfbd"><td class="mdescLeft">&#160;</td><td class="mdescRight">Type for a collection of QOS values. <br/></td></tr>
<tr class="separator:aab7f6333d1b4c20671a879c30139bfbd"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a89204adbc7a5eda14cdabe33607f166f"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a89204adbc7a5eda14cdabe33607f166f">client</a> (const string &amp;serverURI, const string &amp;clientId, <a class="el" href="classmqtt_1_1iclient__persistence.html">iclient_persistence</a> *persistence=nullptr)</td></tr>
<tr class="memdesc:a89204adbc7a5eda14cdabe33607f166f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create a client that can be used to communicate with an MQTT server.  <a href="#a89204adbc7a5eda14cdabe33607f166f">More...</a><br/></td></tr>
<tr class="separator:a89204adbc7a5eda14cdabe33607f166f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad27a329d9e1d0ab8863d43773ac762cc"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#ad27a329d9e1d0ab8863d43773ac762cc">client</a> (const string &amp;serverURI, const string &amp;clientId, const string &amp;persistDir)</td></tr>
<tr class="memdesc:ad27a329d9e1d0ab8863d43773ac762cc"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create an <a class="el" href="classmqtt_1_1async__client.html" title="Lightweight client for talking to an MQTT server using non-blocking methods that allow an operation t...">async_client</a> that can be used to communicate with an MQTT server.  <a href="#ad27a329d9e1d0ab8863d43773ac762cc">More...</a><br/></td></tr>
<tr class="separator:ad27a329d9e1d0ab8863d43773ac762cc"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abc60665765d6340139a1a2633a1d62e6"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#abc60665765d6340139a1a2633a1d62e6">client</a> (const string &amp;serverURI, const string &amp;clientId, int maxBufferedMessages, <a class="el" href="classmqtt_1_1iclient__persistence.html">iclient_persistence</a> *persistence=nullptr)</td></tr>
<tr class="memdesc:abc60665765d6340139a1a2633a1d62e6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create a client that can be used to communicate with an MQTT server, which allows for off-line message buffering.  <a href="#abc60665765d6340139a1a2633a1d62e6">More...</a><br/></td></tr>
<tr class="separator:abc60665765d6340139a1a2633a1d62e6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a331c6374ad34bd3fa181a21650451b8d"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a331c6374ad34bd3fa181a21650451b8d">client</a> (const string &amp;serverURI, const string &amp;clientId, int maxBufferedMessages, const string &amp;persistDir)</td></tr>
<tr class="memdesc:a331c6374ad34bd3fa181a21650451b8d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create a client that can be used to communicate with an MQTT server, which allows for off-line message buffering.  <a href="#a331c6374ad34bd3fa181a21650451b8d">More...</a><br/></td></tr>
<tr class="separator:a331c6374ad34bd3fa181a21650451b8d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad4c593fc1961d56a5cf4082a30a8bf45"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ad4c593fc1961d56a5cf4082a30a8bf45"></a>
virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#ad4c593fc1961d56a5cf4082a30a8bf45">~client</a> ()</td></tr>
<tr class="memdesc:ad4c593fc1961d56a5cf4082a30a8bf45"><td class="mdescLeft">&#160;</td><td class="mdescRight">Virtual destructor. <br/></td></tr>
<tr class="separator:ad4c593fc1961d56a5cf4082a30a8bf45"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8807675e81a186f09eba5b5f050d772c"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a8807675e81a186f09eba5b5f050d772c"></a>
virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a8807675e81a186f09eba5b5f050d772c">connect</a> ()</td></tr>
<tr class="memdesc:a8807675e81a186f09eba5b5f050d772c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Connects to an MQTT server using the default options. <br/></td></tr>
<tr class="separator:a8807675e81a186f09eba5b5f050d772c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a19f8a6093bcf531afe09885e1f4e1de5"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a19f8a6093bcf531afe09885e1f4e1de5">connect</a> (<a class="el" href="classmqtt_1_1connect__options.html">connect_options</a> opts)</td></tr>
<tr class="memdesc:a19f8a6093bcf531afe09885e1f4e1de5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Connects to an MQTT server using the specified options.  <a href="#a19f8a6093bcf531afe09885e1f4e1de5">More...</a><br/></td></tr>
<tr class="separator:a19f8a6093bcf531afe09885e1f4e1de5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a46334d438bbb3204f5b8105277edbfa1"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a46334d438bbb3204f5b8105277edbfa1">reconnect</a> ()</td></tr>
<tr class="memdesc:a46334d438bbb3204f5b8105277edbfa1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Reconnects the client using options from the previous connect.  <a href="#a46334d438bbb3204f5b8105277edbfa1">More...</a><br/></td></tr>
<tr class="separator:a46334d438bbb3204f5b8105277edbfa1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3b0035bbb0a2ecd382a32862323540f8"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a3b0035bbb0a2ecd382a32862323540f8"></a>
virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a3b0035bbb0a2ecd382a32862323540f8">disconnect</a> ()</td></tr>
<tr class="memdesc:a3b0035bbb0a2ecd382a32862323540f8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Disconnects from the server. <br/></td></tr>
<tr class="separator:a3b0035bbb0a2ecd382a32862323540f8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a265207cf3751aaec626b2e0adc404ec1"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a265207cf3751aaec626b2e0adc404ec1">disconnect</a> (int timeoutMS)</td></tr>
<tr class="memdesc:a265207cf3751aaec626b2e0adc404ec1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Disconnects from the server.  <a href="#a265207cf3751aaec626b2e0adc404ec1">More...</a><br/></td></tr>
<tr class="separator:a265207cf3751aaec626b2e0adc404ec1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4aaac9fee1828a55a1473de048117995"><td class="memTemplParams" colspan="2">template&lt;class Rep , class Period &gt; </td></tr>
<tr class="memitem:a4aaac9fee1828a55a1473de048117995"><td class="memTemplItemLeft" align="right" valign="top">void&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a4aaac9fee1828a55a1473de048117995">disconnect</a> (const std::chrono::duration&lt; Rep, Period &gt; &amp;to)</td></tr>
<tr class="memdesc:a4aaac9fee1828a55a1473de048117995"><td class="mdescLeft">&#160;</td><td class="mdescRight">Disconnects from the server.  <a href="#a4aaac9fee1828a55a1473de048117995">More...</a><br/></td></tr>
<tr class="separator:a4aaac9fee1828a55a1473de048117995"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2a732cd4ff04ef7e8fcaa40116df3728"><td class="memItemLeft" align="right" valign="top">virtual string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a2a732cd4ff04ef7e8fcaa40116df3728">get_client_id</a> () const </td></tr>
<tr class="memdesc:a2a732cd4ff04ef7e8fcaa40116df3728"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the client ID used by this client.  <a href="#a2a732cd4ff04ef7e8fcaa40116df3728">More...</a><br/></td></tr>
<tr class="separator:a2a732cd4ff04ef7e8fcaa40116df3728"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a319cb63c7d497904664f105ee0f7d8fa"><td class="memItemLeft" align="right" valign="top">virtual string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a319cb63c7d497904664f105ee0f7d8fa">get_server_uri</a> () const </td></tr>
<tr class="memdesc:a319cb63c7d497904664f105ee0f7d8fa"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the address of the server used by this client.  <a href="#a319cb63c7d497904664f105ee0f7d8fa">More...</a><br/></td></tr>
<tr class="separator:a319cb63c7d497904664f105ee0f7d8fa"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a350673f8b468c49ea93c35535732e9dd"><td class="memItemLeft" align="right" valign="top">virtual std::chrono::milliseconds&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a350673f8b468c49ea93c35535732e9dd">get_timeout</a> () const </td></tr>
<tr class="memdesc:a350673f8b468c49ea93c35535732e9dd"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the maximum time to wait for an action to complete.  <a href="#a350673f8b468c49ea93c35535732e9dd">More...</a><br/></td></tr>
<tr class="separator:a350673f8b468c49ea93c35535732e9dd"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a382c9987d330b66c93dfe809a1f2d595"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classmqtt_1_1topic.html">topic</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a382c9987d330b66c93dfe809a1f2d595">get_topic</a> (const string &amp;top)</td></tr>
<tr class="memdesc:a382c9987d330b66c93dfe809a1f2d595"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get a topic object which can be used to publish messages on this client.  <a href="#a382c9987d330b66c93dfe809a1f2d595">More...</a><br/></td></tr>
<tr class="separator:a382c9987d330b66c93dfe809a1f2d595"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af37670f9792f932e273867a31f8cb2a5"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#af37670f9792f932e273867a31f8cb2a5">is_connected</a> () const </td></tr>
<tr class="memdesc:af37670f9792f932e273867a31f8cb2a5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Determines if this client is currently connected to the server.  <a href="#af37670f9792f932e273867a31f8cb2a5">More...</a><br/></td></tr>
<tr class="separator:af37670f9792f932e273867a31f8cb2a5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8d189ae5704af137c20a8024d440c311"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a8d189ae5704af137c20a8024d440c311">publish</a> (<a class="el" href="classmqtt_1_1buffer__ref.html">string_ref</a> top, const void *payload, size_t n, int qos, bool retained)</td></tr>
<tr class="memdesc:a8d189ae5704af137c20a8024d440c311"><td class="mdescLeft">&#160;</td><td class="mdescRight">Publishes a message to a topic on the server and return once it is delivered.  <a href="#a8d189ae5704af137c20a8024d440c311">More...</a><br/></td></tr>
<tr class="separator:a8d189ae5704af137c20a8024d440c311"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad1ecdeaba58251b1edec1f2cd7d43f5e"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#ad1ecdeaba58251b1edec1f2cd7d43f5e">publish</a> (<a class="el" href="classmqtt_1_1buffer__ref.html">string_ref</a> top, const void *payload, size_t n)</td></tr>
<tr class="memdesc:ad1ecdeaba58251b1edec1f2cd7d43f5e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Publishes a message to a topic on the server and return once it is delivered.  <a href="#ad1ecdeaba58251b1edec1f2cd7d43f5e">More...</a><br/></td></tr>
<tr class="separator:ad1ecdeaba58251b1edec1f2cd7d43f5e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a28bba2c5b9e1bbf0b4a509624b76af45"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a28bba2c5b9e1bbf0b4a509624b76af45">publish</a> (const_message_ptr msg)</td></tr>
<tr class="memdesc:a28bba2c5b9e1bbf0b4a509624b76af45"><td class="mdescLeft">&#160;</td><td class="mdescRight">Publishes a message to a topic on the server.  <a href="#a28bba2c5b9e1bbf0b4a509624b76af45">More...</a><br/></td></tr>
<tr class="separator:a28bba2c5b9e1bbf0b4a509624b76af45"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a23c58f6b35ac3842a68c3a5548db0b9d"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a23c58f6b35ac3842a68c3a5548db0b9d">publish</a> (const <a class="el" href="classmqtt_1_1message.html">message</a> &amp;msg)</td></tr>
<tr class="memdesc:a23c58f6b35ac3842a68c3a5548db0b9d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Publishes a message to a topic on the server.  <a href="#a23c58f6b35ac3842a68c3a5548db0b9d">More...</a><br/></td></tr>
<tr class="separator:a23c58f6b35ac3842a68c3a5548db0b9d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a49d9d64861e7f6bf436b212e26d3ba33"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a49d9d64861e7f6bf436b212e26d3ba33">set_callback</a> (<a class="el" href="classmqtt_1_1callback.html">callback</a> &amp;cb)</td></tr>
<tr class="memdesc:a49d9d64861e7f6bf436b212e26d3ba33"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the callback listener to use for events that happen asynchronously.  <a href="#a49d9d64861e7f6bf436b212e26d3ba33">More...</a><br/></td></tr>
<tr class="separator:a49d9d64861e7f6bf436b212e26d3ba33"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aedb0a9a0bedf95e544a0b8a5764b56ab"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#aedb0a9a0bedf95e544a0b8a5764b56ab">set_timeout</a> (int timeoutMS)</td></tr>
<tr class="memdesc:aedb0a9a0bedf95e544a0b8a5764b56ab"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the maximum time to wait for an action to complete.  <a href="#aedb0a9a0bedf95e544a0b8a5764b56ab">More...</a><br/></td></tr>
<tr class="separator:aedb0a9a0bedf95e544a0b8a5764b56ab"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a74d3c7699b56ea1c7ceaf7a58910c3ca"><td class="memTemplParams" colspan="2">template&lt;class Rep , class Period &gt; </td></tr>
<tr class="memitem:a74d3c7699b56ea1c7ceaf7a58910c3ca"><td class="memTemplItemLeft" align="right" valign="top">void&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a74d3c7699b56ea1c7ceaf7a58910c3ca">set_timeout</a> (const std::chrono::duration&lt; Rep, Period &gt; &amp;to)</td></tr>
<tr class="memdesc:a74d3c7699b56ea1c7ceaf7a58910c3ca"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the maximum time to wait for an action to complete.  <a href="#a74d3c7699b56ea1c7ceaf7a58910c3ca">More...</a><br/></td></tr>
<tr class="separator:a74d3c7699b56ea1c7ceaf7a58910c3ca"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aba3e65033a2e5e2bd5b3235e695744f6"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#aba3e65033a2e5e2bd5b3235e695744f6">subscribe</a> (const string &amp;topicFilter)</td></tr>
<tr class="memdesc:aba3e65033a2e5e2bd5b3235e695744f6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Subscribe to a topic, which may include wildcards using a QoS of 1.  <a href="#aba3e65033a2e5e2bd5b3235e695744f6">More...</a><br/></td></tr>
<tr class="separator:aba3e65033a2e5e2bd5b3235e695744f6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0bced094f95428f53faa8450471af48c"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a0bced094f95428f53faa8450471af48c">subscribe</a> (const string &amp;topicFilter, int qos)</td></tr>
<tr class="memdesc:a0bced094f95428f53faa8450471af48c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Subscribe to a topic, which may include wildcards.  <a href="#a0bced094f95428f53faa8450471af48c">More...</a><br/></td></tr>
<tr class="separator:a0bced094f95428f53faa8450471af48c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8e44cee3866280c3767046bfd6be244a"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a8e44cee3866280c3767046bfd6be244a">subscribe</a> (const <a class="el" href="classmqtt_1_1string__collection.html">string_collection</a> &amp;topicFilters)</td></tr>
<tr class="memdesc:a8e44cee3866280c3767046bfd6be244a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Subscribes to a one or more topics, which may include wildcards using a QoS of 1.  <a href="#a8e44cee3866280c3767046bfd6be244a">More...</a><br/></td></tr>
<tr class="separator:a8e44cee3866280c3767046bfd6be244a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1a75c2496bdfb2fb48208155c0fe4b46"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a1a75c2496bdfb2fb48208155c0fe4b46">subscribe</a> (const <a class="el" href="classmqtt_1_1string__collection.html">string_collection</a> &amp;topicFilters, const <a class="el" href="classmqtt_1_1client.html#aab7f6333d1b4c20671a879c30139bfbd">qos_collection</a> &amp;qos)</td></tr>
<tr class="memdesc:a1a75c2496bdfb2fb48208155c0fe4b46"><td class="mdescLeft">&#160;</td><td class="mdescRight">Subscribes to multiple topics, each of which may include wildcards.  <a href="#a1a75c2496bdfb2fb48208155c0fe4b46">More...</a><br/></td></tr>
<tr class="separator:a1a75c2496bdfb2fb48208155c0fe4b46"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a16bd3d5e33df2082fdff22519c5a8cde"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a16bd3d5e33df2082fdff22519c5a8cde">unsubscribe</a> (const string &amp;topicFilter)</td></tr>
<tr class="memdesc:a16bd3d5e33df2082fdff22519c5a8cde"><td class="mdescLeft">&#160;</td><td class="mdescRight">Requests the server unsubscribe the client from a topic.  <a href="#a16bd3d5e33df2082fdff22519c5a8cde">More...</a><br/></td></tr>
<tr class="separator:a16bd3d5e33df2082fdff22519c5a8cde"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a72feacc13ca065ff5bf325cf90fd7c69"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a72feacc13ca065ff5bf325cf90fd7c69">unsubscribe</a> (const <a class="el" href="classmqtt_1_1string__collection.html">string_collection</a> &amp;topicFilters)</td></tr>
<tr class="memdesc:a72feacc13ca065ff5bf325cf90fd7c69"><td class="mdescLeft">&#160;</td><td class="mdescRight">Requests the server unsubscribe the client from one or more topics.  <a href="#a72feacc13ca065ff5bf325cf90fd7c69">More...</a><br/></td></tr>
<tr class="separator:a72feacc13ca065ff5bf325cf90fd7c69"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7e5ca8022931233cc3d70966d96e668f"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a7e5ca8022931233cc3d70966d96e668f">start_consuming</a> ()</td></tr>
<tr class="memdesc:a7e5ca8022931233cc3d70966d96e668f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Start consuming messages.  <a href="#a7e5ca8022931233cc3d70966d96e668f">More...</a><br/></td></tr>
<tr class="separator:a7e5ca8022931233cc3d70966d96e668f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a16e06de5406920137ce2911484ab8fd5"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a16e06de5406920137ce2911484ab8fd5">stop_consuming</a> ()</td></tr>
<tr class="memdesc:a16e06de5406920137ce2911484ab8fd5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Stop consuming messages.  <a href="#a16e06de5406920137ce2911484ab8fd5">More...</a><br/></td></tr>
<tr class="separator:a16e06de5406920137ce2911484ab8fd5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae0eb28b9ffe328425033726de53495b6"><td class="memItemLeft" align="right" valign="top">const_message_ptr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#ae0eb28b9ffe328425033726de53495b6">consume_message</a> ()</td></tr>
<tr class="memdesc:ae0eb28b9ffe328425033726de53495b6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Read the next message from the queue.  <a href="#ae0eb28b9ffe328425033726de53495b6">More...</a><br/></td></tr>
<tr class="separator:ae0eb28b9ffe328425033726de53495b6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4d759105cc3f9cb15824a37d4f8a39f4"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a4d759105cc3f9cb15824a37d4f8a39f4">try_consume_message</a> (const_message_ptr *msg)</td></tr>
<tr class="memdesc:a4d759105cc3f9cb15824a37d4f8a39f4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Try to read the next message from the queue without blocking.  <a href="#a4d759105cc3f9cb15824a37d4f8a39f4">More...</a><br/></td></tr>
<tr class="separator:a4d759105cc3f9cb15824a37d4f8a39f4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4801f2305d62d1213a8914556319ddb6"><td class="memTemplParams" colspan="2">template&lt;typename Rep , class Period &gt; </td></tr>
<tr class="memitem:a4801f2305d62d1213a8914556319ddb6"><td class="memTemplItemLeft" align="right" valign="top">bool&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a4801f2305d62d1213a8914556319ddb6">try_consume_message_for</a> (const_message_ptr *msg, const std::chrono::duration&lt; Rep, Period &gt; &amp;relTime)</td></tr>
<tr class="memdesc:a4801f2305d62d1213a8914556319ddb6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Waits a limited time for a message to arrive.  <a href="#a4801f2305d62d1213a8914556319ddb6">More...</a><br/></td></tr>
<tr class="separator:a4801f2305d62d1213a8914556319ddb6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1a98495d611332f8095f895168891181"><td class="memTemplParams" colspan="2">template&lt;class Clock , class Duration &gt; </td></tr>
<tr class="memitem:a1a98495d611332f8095f895168891181"><td class="memTemplItemLeft" align="right" valign="top">bool&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classmqtt_1_1client.html#a1a98495d611332f8095f895168891181">try_consume_message_until</a> (const_message_ptr *msg, const std::chrono::time_point&lt; Clock, Duration &gt; &amp;absTime)</td></tr>
<tr class="memdesc:a1a98495d611332f8095f895168891181"><td class="mdescLeft">&#160;</td><td class="mdescRight">Waits until a specific time for a message to occur.  <a href="#a1a98495d611332f8095f895168891181">More...</a><br/></td></tr>
<tr class="separator:a1a98495d611332f8095f895168891181"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Lightweight client for talking to an MQTT server using methods that block until an operation completes. </p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a89204adbc7a5eda14cdabe33607f166f"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">mqtt::client::client </td>
          <td>(</td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>serverURI</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>clientId</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classmqtt_1_1iclient__persistence.html">iclient_persistence</a> *&#160;</td>
          <td class="paramname"><em>persistence</em> = <code>nullptr</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Create a client that can be used to communicate with an MQTT server. </p>
<p>This allows the caller to specify a user-defined persistence object, or use no persistence. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">serverURI</td><td>the address of the server to connect to, specified as a URI. </td></tr>
    <tr><td class="paramname">clientId</td><td>a client identifier that is unique on the server being connected to </td></tr>
    <tr><td class="paramname">persistence</td><td>The user persistence structure. If this is null, then no persistence is used. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ad27a329d9e1d0ab8863d43773ac762cc"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">mqtt::client::client </td>
          <td>(</td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>serverURI</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>clientId</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>persistDir</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Create an <a class="el" href="classmqtt_1_1async__client.html" title="Lightweight client for talking to an MQTT server using non-blocking methods that allow an operation t...">async_client</a> that can be used to communicate with an MQTT server. </p>
<p>This uses file-based persistence in the specified directory. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">serverURI</td><td>the address of the server to connect to, specified as a URI. </td></tr>
    <tr><td class="paramname">clientId</td><td>a client identifier that is unique on the server being connected to </td></tr>
    <tr><td class="paramname">persistDir</td><td>The directory to use for persistence data </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="abc60665765d6340139a1a2633a1d62e6"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">mqtt::client::client </td>
          <td>(</td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>serverURI</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>clientId</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>maxBufferedMessages</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classmqtt_1_1iclient__persistence.html">iclient_persistence</a> *&#160;</td>
          <td class="paramname"><em>persistence</em> = <code>nullptr</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Create a client that can be used to communicate with an MQTT server, which allows for off-line message buffering. </p>
<p>This allows the caller to specify a user-defined persistence object, or use no persistence. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">serverURI</td><td>the address of the server to connect to, specified as a URI. </td></tr>
    <tr><td class="paramname">clientId</td><td>a client identifier that is unique on the server being connected to </td></tr>
    <tr><td class="paramname">maxBufferedMessages</td><td>the maximum number of messages allowed to be buffered while not connected </td></tr>
    <tr><td class="paramname">persistence</td><td>The user persistence structure. If this is null, then no persistence is used. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a331c6374ad34bd3fa181a21650451b8d"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">mqtt::client::client </td>
          <td>(</td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>serverURI</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>clientId</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>maxBufferedMessages</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>persistDir</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Create a client that can be used to communicate with an MQTT server, which allows for off-line message buffering. </p>
<p>This uses file-based persistence in the specified directory. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">serverURI</td><td>the address of the server to connect to, specified as a URI. </td></tr>
    <tr><td class="paramname">clientId</td><td>a client identifier that is unique on the server being connected to </td></tr>
    <tr><td class="paramname">maxBufferedMessages</td><td>the maximum number of messages allowed to be buffered while not connected </td></tr>
    <tr><td class="paramname">persistDir</td><td>The directory to use for persistence data </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="a19f8a6093bcf531afe09885e1f4e1de5"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::connect </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classmqtt_1_1connect__options.html">connect_options</a>&#160;</td>
          <td class="paramname"><em>opts</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Connects to an MQTT server using the specified options. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">opts</td><td></td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ae0eb28b9ffe328425033726de53495b6"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">const_message_ptr mqtt::client::consume_message </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Read the next message from the queue. </p>
<p>This blocks until a new message arrives. </p>
<dl class="section return"><dt>Returns</dt><dd>The message and topic. </dd></dl>

</div>
</div>
<a class="anchor" id="a265207cf3751aaec626b2e0adc404ec1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::disconnect </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>timeoutMS</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Disconnects from the server. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">timeoutMS</td><td>the amount of time in milliseconds to allow for existing work to finish before disconnecting. A value of zero or less means the client will not quiesce. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a4aaac9fee1828a55a1473de048117995"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class Rep , class Period &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void mqtt::client::disconnect </td>
          <td>(</td>
          <td class="paramtype">const std::chrono::duration&lt; Rep, Period &gt; &amp;&#160;</td>
          <td class="paramname"><em>to</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Disconnects from the server. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">to</td><td>the amount of time in milliseconds to allow for existing work to finish before disconnecting. A value of zero or less means the client will not quiesce. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a2a732cd4ff04ef7e8fcaa40116df3728"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual string mqtt::client::get_client_id </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Gets the client ID used by this client. </p>
<dl class="section return"><dt>Returns</dt><dd>The client ID used by this client. </dd></dl>

</div>
</div>
<a class="anchor" id="a319cb63c7d497904664f105ee0f7d8fa"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual string mqtt::client::get_server_uri </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Gets the address of the server used by this client. </p>
<dl class="section return"><dt>Returns</dt><dd>The address of the server used by this client, as a URI. </dd></dl>

</div>
</div>
<a class="anchor" id="a350673f8b468c49ea93c35535732e9dd"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual std::chrono::milliseconds mqtt::client::get_timeout </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Return the maximum time to wait for an action to complete. </p>
<dl class="section return"><dt>Returns</dt><dd>int </dd></dl>

</div>
</div>
<a class="anchor" id="a382c9987d330b66c93dfe809a1f2d595"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classmqtt_1_1topic.html">topic</a> mqtt::client::get_topic </td>
          <td>(</td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>top</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Get a topic object which can be used to publish messages on this client. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">top</td><td>The topic name </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A topic attached to this client. </dd></dl>

</div>
</div>
<a class="anchor" id="af37670f9792f932e273867a31f8cb2a5"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool mqtt::client::is_connected </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Determines if this client is currently connected to the server. </p>
<dl class="section return"><dt>Returns</dt><dd><em>true</em> if the client is currently connected, <em>false</em> if not. </dd></dl>

</div>
</div>
<a class="anchor" id="a8d189ae5704af137c20a8024d440c311"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::publish </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classmqtt_1_1buffer__ref.html">string_ref</a>&#160;</td>
          <td class="paramname"><em>top</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const void *&#160;</td>
          <td class="paramname"><em>payload</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>n</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>qos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>retained</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Publishes a message to a topic on the server and return once it is delivered. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">top</td><td>The topic to publish </td></tr>
    <tr><td class="paramname">payload</td><td>The data to publish </td></tr>
    <tr><td class="paramname">n</td><td>The size in bytes of the data </td></tr>
    <tr><td class="paramname">qos</td><td>The QoS for message delivery </td></tr>
    <tr><td class="paramname">retained</td><td>Whether the broker should retain the message </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ad1ecdeaba58251b1edec1f2cd7d43f5e"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::publish </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classmqtt_1_1buffer__ref.html">string_ref</a>&#160;</td>
          <td class="paramname"><em>top</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const void *&#160;</td>
          <td class="paramname"><em>payload</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Publishes a message to a topic on the server and return once it is delivered. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">top</td><td>The topic to publish </td></tr>
    <tr><td class="paramname">payload</td><td>The data to publish </td></tr>
    <tr><td class="paramname">n</td><td>The size in bytes of the data </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a28bba2c5b9e1bbf0b4a509624b76af45"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::publish </td>
          <td>(</td>
          <td class="paramtype">const_message_ptr&#160;</td>
          <td class="paramname"><em>msg</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Publishes a message to a topic on the server. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">msg</td><td>The message </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a23c58f6b35ac3842a68c3a5548db0b9d"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::publish </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmqtt_1_1message.html">message</a> &amp;&#160;</td>
          <td class="paramname"><em>msg</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Publishes a message to a topic on the server. </p>
<p>This version will not timeout since that could leave the library with a reference to memory that could disappear while the library is still using it. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">msg</td><td>The message </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a46334d438bbb3204f5b8105277edbfa1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::reconnect </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Reconnects the client using options from the previous connect. </p>
<p>The client must have previously called <a class="el" href="classmqtt_1_1client.html#a8807675e81a186f09eba5b5f050d772c" title="Connects to an MQTT server using the default options. ">connect()</a> for this to work. </p>

</div>
</div>
<a class="anchor" id="a49d9d64861e7f6bf436b212e26d3ba33"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::set_callback </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classmqtt_1_1callback.html">callback</a> &amp;&#160;</td>
          <td class="paramname"><em>cb</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Sets the callback listener to use for events that happen asynchronously. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">cb</td><td>The callback functions </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="aedb0a9a0bedf95e544a0b8a5764b56ab"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::set_timeout </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>timeoutMS</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Set the maximum time to wait for an action to complete. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">timeoutMS</td><td>The timeout in milliseconds </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a74d3c7699b56ea1c7ceaf7a58910c3ca"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class Rep , class Period &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void mqtt::client::set_timeout </td>
          <td>(</td>
          <td class="paramtype">const std::chrono::duration&lt; Rep, Period &gt; &amp;&#160;</td>
          <td class="paramname"><em>to</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Set the maximum time to wait for an action to complete. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">to</td><td>The timeout as a std::chrono duration. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a7e5ca8022931233cc3d70966d96e668f"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void mqtt::client::start_consuming </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Start consuming messages. </p>
<p>This initializes the client to receive messages through a queue that can be read synchronously. </p>

</div>
</div>
<a class="anchor" id="a16e06de5406920137ce2911484ab8fd5"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void mqtt::client::stop_consuming </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Stop consuming messages. </p>
<p>This shuts down the internal callback and discards any unread messages. </p>

</div>
</div>
<a class="anchor" id="aba3e65033a2e5e2bd5b3235e695744f6"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::subscribe </td>
          <td>(</td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>topicFilter</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Subscribe to a topic, which may include wildcards using a QoS of 1. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">topicFilter</td><td></td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a0bced094f95428f53faa8450471af48c"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::subscribe </td>
          <td>(</td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>topicFilter</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>qos</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Subscribe to a topic, which may include wildcards. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">topicFilter</td><td>A single topic to subscribe </td></tr>
    <tr><td class="paramname">qos</td><td>The QoS of the subscription </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a8e44cee3866280c3767046bfd6be244a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::subscribe </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmqtt_1_1string__collection.html">string_collection</a> &amp;&#160;</td>
          <td class="paramname"><em>topicFilters</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Subscribes to a one or more topics, which may include wildcards using a QoS of 1. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">topicFilters</td><td>A set of topics to subscribe </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a1a75c2496bdfb2fb48208155c0fe4b46"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::subscribe </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmqtt_1_1string__collection.html">string_collection</a> &amp;&#160;</td>
          <td class="paramname"><em>topicFilters</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classmqtt_1_1client.html#aab7f6333d1b4c20671a879c30139bfbd">qos_collection</a> &amp;&#160;</td>
          <td class="paramname"><em>qos</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Subscribes to multiple topics, each of which may include wildcards. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">topicFilters</td><td>A collection of topics to subscribe </td></tr>
    <tr><td class="paramname">qos</td><td>A collection of QoS for each topic </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a4d759105cc3f9cb15824a37d4f8a39f4"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool mqtt::client::try_consume_message </td>
          <td>(</td>
          <td class="paramtype">const_message_ptr *&#160;</td>
          <td class="paramname"><em>msg</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Try to read the next message from the queue without blocking. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">msg</td><td>Pointer to the value to receive the message </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><em>true</em> is a message was read, <em>false</em> if no message was available. </dd></dl>

</div>
</div>
<a class="anchor" id="a4801f2305d62d1213a8914556319ddb6"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Rep , class Period &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool mqtt::client::try_consume_message_for </td>
          <td>(</td>
          <td class="paramtype">const_message_ptr *&#160;</td>
          <td class="paramname"><em>msg</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::chrono::duration&lt; Rep, Period &gt; &amp;&#160;</td>
          <td class="paramname"><em>relTime</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Waits a limited time for a message to arrive. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">msg</td><td>Pointer to the value to receive the message </td></tr>
    <tr><td class="paramname">relTime</td><td>The maximum amount of time to wait for a message. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><em>true</em> if a message was read, <em>false</em> if a timeout occurred. </dd></dl>

</div>
</div>
<a class="anchor" id="a1a98495d611332f8095f895168891181"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class Clock , class Duration &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool mqtt::client::try_consume_message_until </td>
          <td>(</td>
          <td class="paramtype">const_message_ptr *&#160;</td>
          <td class="paramname"><em>msg</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::chrono::time_point&lt; Clock, Duration &gt; &amp;&#160;</td>
          <td class="paramname"><em>absTime</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Waits until a specific time for a message to occur. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">msg</td><td>Pointer to the value to receive the message </td></tr>
    <tr><td class="paramname">absTime</td><td>The time point to wait until, before timing out. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><em>true</em> if a message was read, <em>false</em> if a timeout occurred. </dd></dl>

</div>
</div>
<a class="anchor" id="a16bd3d5e33df2082fdff22519c5a8cde"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::unsubscribe </td>
          <td>(</td>
          <td class="paramtype">const string &amp;&#160;</td>
          <td class="paramname"><em>topicFilter</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Requests the server unsubscribe the client from a topic. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">topicFilter</td><td>A single topic to unsubscribe. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a72feacc13ca065ff5bf325cf90fd7c69"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mqtt::client::unsubscribe </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmqtt_1_1string__collection.html">string_collection</a> &amp;&#160;</td>
          <td class="paramname"><em>topicFilters</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Requests the server unsubscribe the client from one or more topics. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">topicFilters</td><td>A collection of topics to unsubscribe. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>src/mqtt/<a class="el" href="client_8h_source.html">client.h</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><b>mqtt</b></li><li class="navelem"><a class="el" href="classmqtt_1_1client.html">client</a></li>
    <li class="footer">Generated on Sun Jul 23 2017 10:24:29 for Paho C++ by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.6 </li>
  </ul>
</div>
</body>
</html>
